import request from '@/utils/request'
// 检验单据列表
export function GetListAPI(params) {
  return request({
    url: '/quality/quality-inspection-document/list',
    method: 'GET',
    params
  })
}

/*
 检验单据 SAT ================================>
*/

// 获取条数(检验进度总条数)
export function GetTotalSizeAPI(params) {
  return request({
    url: '/quality/quality-temporary/getTotalSize',
    method: 'GET',
    params
  })
}

// 物料号码右侧列表
export function GetSampleAPI(params) {
  return request({
    url: '/quality/quality-bad-sample/list',
    method: 'GET',
    params
  })
}

// 获取检验数量
export function GetNumAPI(params) {
  return request({
    url: '/quality/quality-bad-sample/getNum',
    method: 'GET',
    params
  })
}

// 右侧列表删除
export function DeleteNumAPI(params) {
  return request({
    url: '/quality/quality-bad-sample/delete',
    method: 'DELETE',
    params
  })
}

// 下方列表
export function SampleInspectionAPI(params) {
  return request({
    url: '/quality/quality-inspection-document/sampleInspection',
    method: 'GET',
    params
  })
}

// 获取物料号码
export function GetMaterialNumberAPI(params) {
  return request({
    url: '/quality/quality-temporary/getMaterialNumber',
    method: 'GET',
    params
  })
}

// 保存（样品信息）小保存
export function InformationAPI(data) {
  return request({
    url: '/quality/quality-sample-information/add',
    method: 'POST',
    data
  })
}

// 样本信息列表
export function GetInformationListAPI(params) {
  return request({
    url: '/quality/quality-sample-information/list',
    method: 'GET',
    params
  })
}

// 物料信息列表
export function GetTemporaryListAPI(params) {
  return request({
    url: '/quality/quality-temporary/list',
    method: 'GET',
    params
  })
}

// 详情
export function GetDetailsAPI(params) {
  return request({
    url: '/quality/quality-inspection-document/view/' + params,
    method: 'GET'
  })
}

// 新增
export function AddDataAPI(data) {
  return request({
    url: '/quality/quality-sample-information/addDocument',
    method: 'POST',
    data
  })
}

// 品质处理列表查询
export function GetTmporaryAPI(params) {
  return request({
    url: '/quality/quality-temporary/list',
    method: 'GET',
    params
  })
}

// 品质处理提交
export function QualityTreatmentAPI(data) {
  return request({
    url: '/quality/quality-inspection-document/qualityTreatment',
    method: 'POST',
    data
  })
}

// 品质处理提交
export function ProcessingIncomingMaterialsAPI(data) {
  return request({
    url: '/quality/quality-inspection-document/processingIncomingMaterials',
    method: 'POST',
    data
  })
}
// 批量审核
export function BatchAuditAPI(data) {
  return request({
    url: '/quality/quality-inspection-document/batchAudit',
    method: 'POST',
    data
  })
}

/*
 检验单据 END ================================>
*/
